package com.tarena.lbs.basic.web.rpc;

import com.tarena.lbs.basic.api.AdminApi;
import com.tarena.lbs.basic.web.service.AdminService;
import com.tarena.lbs.pojo.basic.dto.AdminDTO;
import lombok.extern.slf4j.Slf4j;
import org.apache.dubbo.config.annotation.DubboService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;
@DubboService
@Component
@Slf4j
public class AdminApiImpl implements AdminApi {
    @Autowired
    private AdminService adminService;

    @Override
    public AdminDTO getAdminDetail(Integer adminId) {
        try{
            return adminService.adminDetail(adminId);
        }catch (Exception e){
            log.error("查询后台账号详情 异常,",e);
        }
        return null;
    }
}
